package com.plm.frame.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.plm.frame.mapper.CartMapper;
import com.plm.frame.model.Cart;
import com.plm.frame.service.CartService;



@Service
@Transactional  //此处不再进行创建SqlSession和提交事务，都已交由spring去管理了。
public class CartServiceImpl implements CartService {
	
	@Resource
	private CartMapper mapper;

	@Override
	public List<Cart> selectCart(Cart cart) {
		// TODO Auto-generated method stub
		return mapper.selectCart(cart);
	}

	@Override
	public void addCart(Cart cart) {
		// TODO Auto-generated method stub
		mapper.addCart(cart);
	}

	@Override
	public void deleteCart(Cart cart) {
		// TODO Auto-generated method stub
		mapper.deleteCart(cart);
	}


}
